<script>
export default {
	onLaunch: function (options) {
		// console.log(uni.$u.config.v);
		this.$store.dispatch('user/getOpenid')
		// this.$store.dispatch('user/getUserinfo')
		if (uni.getStorageSync('token')){
			// this.$store.dispatch('user/getUserinfo')
			// this.$store.dispatch('user/getQiniuToken')
		}
		let updateManager = uni.getUpdateManager()
		updateManager.onCheckForUpdate(function (res) {
		  console.log('onCheckForUpdate', res.hasUpdate)
		})
		
		updateManager.onUpdateReady(function () {
		  uni.showModal({
		    title: '更新提示',
		    content: '新版本已经准备好,是否重启应用?',
		    showCancel: false,
		    mask: true,
		    success(res) {
		      if (res.confirm) {
		        updateManager.applyUpdate()
		      }
		    }
		  })
		})
		
		updateManager.onUpdateFailed(function () {
		  uni.showToast({
		    title: '版本下载失败',
		    mask: true
		  })
		})
	},
	methods: {

	},
	onShow: function (options) {

	},
	onHide: function () {
		console.log('App Hide')
	}
	
}
</script>
<style>
page {
  background-color: #F8F8F8;
}
</style>
<style lang="scss">
	::-webkit-scrollbar{
	      display: none;
	}
	::v-deep{
		.u-tabbar__content{
			// border-top: 1rpx solid #f5dac9;
		}
		.u-tabbar__content__item{
			position: relative;
		}
		.u-tabbar__content__item:nth-child(1)::after{
			content: " ";
			width: 37.66rpx;
			height: 32.53rpx;
			// background: url(/static/r1.png) no-repeat;
			background-size: 100% 100%;
			position: absolute;
			left: 6%;
			top: 5%;
		}
		.u-tabbar__content__item:nth-child(4)::after{
			content: " ";
			width: 37.66rpx;
			height: 32.53rpx;
			// background: url(/static/r.png) no-repeat;
			background-size: 100% 100%;
			position: absolute;
			right: 6%;
			top: 5%;
		}
		.u-tabbar__content__circle__button{
			    width: 148rpx !important;
			        height: 70rpx !important;
			        // border-radius: 100% !important;
			    display: flex;
			    flex-direction: row;
			    justify-content: center;
			    align-items: center;
			    position: absolute;
			    background-color: #ffffff08 !important;
			    top: -19rpx !important;
			    left: 50% !important;
			    z-index: 6;
			    -webkit-transform: translateX(-50%);
			    transform: translateX(-50%);
				background: url(https://img.shihhl.com/jinye/index_fbl.png) no-repeat;
				background-size: 100% 100%;
		}
		.u-tabbar__content__item{
			padding: 0 !important;
		}
		.u-tabbar__content__item__text{
			    bottom: 8rpx !important;
		}
		.u-tabbar__content__circle__border{
			width: 0% !important;
			height: 0 !important;
		}
	}
	image{
		height: auto;
	}
	@import "uview-ui/index.scss";
</style>
